package org.fuys.coder.domain.act.lottery.repository;

import org.fuys.coder.common.entity.Pair;
import org.fuys.coder.domain.act.lottery.model.req.act.LotteryActivityAddReq;
import org.fuys.coder.domain.act.lottery.model.vo.activity.LotteryActVO;
import org.fuys.coder.common.entity.PageDTO;

import java.util.Date;
import java.util.List;

/**
 * @projectName: fuys-low-coder
 * @package: org.fuys.coder.domain.lottery.repository
 * @className: ILotteryActivity
 * @author: WangJing
 * @description: 抽奖活动仓储服务
 * @date: 2024/7/5 22:47
 * @version: 1.0
 */
public interface ILotteryActivityRepository {
    Long addLotteryActInfo(LotteryActivityAddReq req);

    LotteryActVO getById(Long actId,Integer state);

    List<LotteryActVO> getCurAct(int num);

    Pair<List<LotteryActVO>,Long> getPage(PageDTO pageDTO);

    boolean checkUserTakeCount(Integer userId,Long actId);

    Integer getStrategyId(Long actId);

    void addLotteryTakeRecord(Integer userId, Long actId, String code, Long awardId, Date expire,Integer type);
}
